using SurveySez.Model;

namespace SurveySez.ViewModel.Editor
{
	public class ResponseViewModel
	{
		private Response _response;

		public ResponseViewModel(Response response)
		{
			_response = response;
		}

		public Response Response
		{
			get { return _response; }
		}

		public string Answer
		{
			get { return _response.Answer; }
			set { _response.Answer = value; }
		}

		public override bool Equals(object obj)
		{
			if (obj == this)
				return true;
			ResponseViewModel that = obj as ResponseViewModel;
			if (that == null)
				return false;
			return this._response == that._response;
		}

		public override int GetHashCode()
		{
			return _response.GetHashCode();
		}
	}
}
